package cn.netbox.spring.ZLQhandler;

import org.aspectj.lang.annotation.After;
import org.aspectj.lang.annotation.Aspect;
import org.aspectj.lang.annotation.Before;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Component;

import java.util.Date;

/**
 * description:
 * date: 2021/12/1 16:29
 * author: Alex
 * version: 1.0
 */
@Aspect
@Component("zlqAspect")
public class MyAspect {

    @Before(value = "execution(public void cn.netbox.spring.ZLQservive.impl.ZhongJieSeriveProxy.kanFang())")
    public void method() {
        System.out.println("Log:当前时间"+new Date());
    }

    @After(value = "execution(public void cn.netbox.spring.ZLQservive.impl.ZhongJieSeriveProxy.shouZu())")
    public void method02(){
        System.out.println("提交事务");
    }
}
